package avicit.j2ee.servlet;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

@SuppressWarnings("serial")
public class GeyfServlet extends HttpServlet {

	@Override
	protected void doGet(HttpServletRequest req, HttpServletResponse res)
			throws ServletException, IOException {
		// TODO Auto-generated method stub
		doPost(req,res);
	}

	@Override
	protected void doPost(HttpServletRequest req, HttpServletResponse res)
			throws ServletException, IOException {
		// TODO Auto-generated method stub
		String username = req.getParameter("username");
		String password = req.getParameter("password");
		
		res.setContentType("text/html;charset=GB18030");
		
        res.getWriter().println("<html>");  
        res.getWriter().println("<head>");     
        res.getWriter().println("<title>登录信息</title>");      
        res.getWriter().println("</head>");    
        res.getWriter().println("<body>");     
        res.getWriter().println("欢迎【" + username + "】用户登录成功！！！");    
        res.getWriter().println("</body>");    
        res.getWriter().println("</html>");  
//		doGet(req,resp);
	}


}
